package com.sztest.jayjun.utils;

import android.provider.Settings;

import com.sztest.jayjun.MyApplication;

/*
 *  @项目名：  jayjun
 *  @包名：    com.sztest.jayjun.utils
 *  @文件名:   PumpThreadUtils
 *  @创建者:   okmin
 *  @创建时间:  2022/7/8 14:23
 *  @描述：    TODO
 */
public class ADCThread extends Thread {

    final String TAG="ADCThread";

    volatile  int mTime=100;

    volatile boolean exit;

    volatile int mPa;

    @Override
    public void run() {
        while (!exit){

            try {
                sleep(mTime);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            int air = MyApplication.getInstance().get_mPa();
            System.out.println("pa="+air);
            mPa=air;
        }


    }

    public int getPa(){
        return mPa;
    }

    public void setExit(boolean exit) {
        this.exit = exit;
    }

}
